CREATE PROCEDURE RRHH_OBTENER_CARGO_L
@AREA VARCHAR(100)
AS

--SET TRANSACTION ISOLATION LEVEL SERIALIZABLE

BEGIN TRANSACTION
BEGIN TRY
	SELECT c.idCargo, c.idArea, c.DESCRIPCION 
	FROM AREA A, CARGO C
	WHERE @AREA=A.DESCRIPCION AND A.IDAREA=C.IDAREA
	
	COMMIT TRANSACTION
END TRY
BEGIN CATCH
	ROLLBACK TRANSACTION
END CATCH